<div>
<ul id="events">
<?php foreach ($this->events as $event): ?>
<li>
<div>
	<a href="<?php echo $this->url(array('controller' => 'event' ,'id' => $event->id), 'def' ,true);?>">	
	<span>
		<?php if($event->status == 'opened'): ?>
			<?php echo $event->title; ?>
		<?php else:?>			
			<?php echo $event->getTeamL()->title; ?>
				<?php echo $event->score_left; ?>
				 : 
				<?php echo $event->score_right; ?>
			<?php echo $event->getTeamR()->title; ?>			
		<?php endif; ?>
	</span>
	<span class="date">
		Start at: <?php echo $event->date_start; ?>
	</span>
	</a>
</div>
</li>
<?php endforeach;?>
</ul>
</div>